<?php
if ($_POST['submit'] == "Install now!") {
	$db = new SQLiteDatabase("dummychat.db", 0666, $sqerr);
	
	$db -> query('CREATE TABLE UserDB (UID INTEGER PRIMARY KEY, username VARCHAR(20), password VARCHAR(20), status INT, address VARCHAR(15))');
}
?>


<h1>Setup page</h1>

View this page to setup the database. </br></br>

Database status is :
<?php
if ( file_exists("dummychat.db") ) {?>
	<span style="color:green">Installed</span><?php
}
else {?>
	<span style="color:red">Not Installed</span>
	
	<form action="" method="POST">
		<input type="submit" name="submit" value="Install now!">
	</form><?php
}